
import {UPDATE_GRAGE_LIST,UPDATE_GRAGE_DETAIL} from "./types";

export default {
    // 更新list
    [UPDATE_GRAGE_LIST](state,payload){
        state.list = payload;
    },
    // 向list中新增数据
    // [ADD_GRAGE_LIST](state,payload){
    //     state.list.push(payload);
    // },
    [UPDATE_GRAGE_DETAIL](state,payload){
        var {total=0,maxPage=0,current=1} = payload
        state.total = total;
        state.maxPage = maxPage;
        state.current = current;
    }
}